package com.bruce.spring.http.client.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.UUID;

/**
 * @author bruce 2025/7/26 22:04
 */
@Slf4j
@RestController
public class TestController {

    @RequestMapping("/test")
    public String test() {
        StringBuilder stringBuilder = new StringBuilder();
        stringBuilder.append("start!!!");

        for (int i = 0; i < 5; i++) {
            stringBuilder.append("1752719455000|2025-07-17 10:30:55|").append(UUID.randomUUID()).append("|0|0|5|0|1355|0|0|1").append(i).append("\n");
        }
        stringBuilder.append("end!!!");

        log.info("原始文本大小:{}", stringBuilder.toString().length());

        return stringBuilder.toString();
    }


    @RequestMapping("/test2")
    public String test2() {
        log.info("test2");
        return "success";
    }


}
